# Heritage site-seeing through the visitor's lens on Instagram

Code accompanying the manuscript:

1. `1_scrape_instaphyte.ipynb`: Uses [Instaphyte](https://github.com/ScriptSmith/instaphyte/tree/master/instaphyte) to scrape Instragram images of English heritage sites listed in `EH_Instagram_v2.0.xlsx`. This was run in May 2019.
2. `2_posting_patterns.ipynb`: Analyses posting patterns across heritage sites and time.
3. `3_offtheshelf_inference.ipynb`: Runs off-the-shelf object detection on images of the top five heritage sites.
4. `4_annotate_images.ipynb`: Randomly allocates Instagram images for Rollright Stones to four coders for manual annotation.
5. `5_finetune`: Directory contains the command and files used to fine-tune a pre-trained TensortFlow object detection model on the Google Cloud ML Engine for annotated Rollright Stones images.
6. `6_export_inference_graph`: Directory contains the frozen inference graph of the fine-tuned object detection model and the command to export it.
7. `7_finetune_inference.ipynb`: Conducts inference using the fine-tuned object detection model on Instagram images of Rollright Stones.
8. `8_evaluate_model.ipynb`: Evaluates the fine-tuned model using the PASCAL VOC AP metric with `pascalvoc.py`.
9. `9_analyse_objects.ipynb`: Analyses objects that visitors take photographs of at the top five heritage sites, incorporating the fine-tuned model's inferences for Rollright Stones.